package cate.game.role.farm.guildBoss.msg;

import cate.game.GameBody;
import cate.game.client.ClientContext;
import cate.game.client.msg.ClientMsg;
import cate.game.client.msg.MsgConfig;
import cate.game.client.msg.MsgInput;
import cate.game.client.msg.id.MsgIdGuild;
import cate.game.role.Role;
import easy.java.practice.errorcode.EcResult;

@ClientMsg(title = "公会BOSS吹响集结号角 の 请求")
public class GuildBossHornReq implements MsgInput {

    @Override
    public MsgConfig conf() {
        return MsgIdGuild.GUILD_BOSS_HORN_REQ;
    }

    @Override
    public void execute(GameBody game, ClientContext cc) {
        Role role = cc.getRole();
        EcResult r = role.getFarm().guildBoss.horn();
        if(!r.ok()){
            game.notice.message(cc.getRole(), r.message);
        }
    }
}
